import request from '../utils/request';

// 条件分页查询班级
export function cfindClazz(name, begin, end, page, pageSize)
{
  return request.get(`/clazzs?name=${name}&begin=${begin}&end=${end}&page=${page}&pageSize=${pageSize}`)
}

// 添加班级
export function addClazzApi(clazz)
{
  return request.post('/clazzs', clazz)
}

// 根据Id查询班级
export function selectClazzByIdApi(id)
{
  return request.get(`/clazzs/${id}`)
}

// 根据Id修改班级
export function updateClazzByIdApi(clazz)
{
  return request.put('/clazzs', clazz)
}

// 根据Id删除班级
export function deleteClazzByIdApi(id)
{
  return request.delete(`/clazzs/${id}`)
}

// 查询所有班级
export function findAllClazzApi()
{
  return request.get('/clazzs/list')
}